package com.istock.state.mock;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;

import com.istock.mock.ApplyInfoStatusEnum;
import com.istock.state.mock.model.ApplyInfo;

public class ApplyInfoTask {

	@Autowired
	private ApplyInfoService service;
	
	public void scanApplyInfo() {
		List<ApplyInfo> list = service.findApplyNoHandler();
		if(list != null && list.size()>0) {
			for(ApplyInfo info : list) {
				service.changeStatus(info.getId(), ApplyInfoStatusEnum.S);
			}
		}
	}
}
